import { ColumnGroupType, ColumnType } from "antd/es/table"

const chatBarrageList = (newFormat: (arg: string) => string): Record<string, ColumnGroupType<any> | ColumnType<any>> => ({
	chatBarrageTableList_sort: {
		key: "chatBarrageTableList_sort",
		align: "center",
		dataIndex: "sort",
		title: newFormat("dxn.service_manager.sort"),
		width: 100,
		render: (sort: number) => <span>{sort}</span>
	},
	chatBarrageTableList_content: {
		key: "chatBarrageTableList_content",
		align: "center",
		dataIndex: "content",
		title: newFormat("dxn.service_manager.barrage_content"),
		width: 350
	},
	chatBarrageTableList_content1: {
		key: "chatBarrageTableList_content1",
		align: "center",
		dataIndex: "updatedBy",
		title: newFormat("common.last_updateBy"),
		width: 120
	},
	chatBarrageTableList_createAt: {
		key: "chatBarrageTableList_dateTime",
		align: "center",
		dataIndex: "createAt",
		title: newFormat("common.createAt"),
		width: 200
	},
	chatBarrageTableList_last_updateAt: {
		key: "chatBarrageTableList_dateTime",
		align: "center",
		dataIndex: "updateAt",
		title: newFormat("common.last_updateAt"),
		width: 200
	},
	chatBarrageTableList_status: {
		key: "chatBarrageTableList_dateTime",
		align: "center",
		dataIndex: "state",
		title: newFormat("common.status"),
		width: 100
	},
	chatBarrageTableList_action: {
		key: "chatBarrageTableList_action",
		align: "center",
		dataIndex: "action",
		title: newFormat("common.actions"),
		width: 200
	}
})
export default chatBarrageList
